﻿namespace HQS.TokenInterpolation.Tokens
{
    [Token(Name = "if")]
    public class If : AbstractToken
    {
        [TokenProperty("expression", true)]
        public string Expression { get; set; }

        [TokenProperty("then", true)]
        public string Then { get; set; }

        [TokenProperty("else", true)]
        public string Else { get; set; }

        protected override TokenRuntimeValue OnAccept(IDataSourcesVisitor context)
        {
            return context.Visit(this);
        }
    }
}